package p2pcdnsim.cdn;

public class VideoContent extends ObjectContent {

	private int bitRate;
	private boolean fragment;
	private boolean lastFragment;
	private long totalSize;
	
	public long getTotalSize() {
		return totalSize;
	}

	public VideoContent(long objid, long length, int bitRate) {
		super(objid, length);
		this.setBitRate(bitRate);
	}

	public void setBitRate(int bitRate) {
		this.bitRate = bitRate;
	}

	public int getBitRate() {
		return bitRate;
	}

	public void setFragment(boolean fragment) {
		this.fragment = fragment;
	}

	public boolean isFragment() {
		return fragment;
	}

	public void setLastFragment(boolean lastFragment) {
		this.lastFragment = lastFragment;
	}

	public boolean isLastFragment() {
		return lastFragment;
	}
	
	public String toString() {
		return "Video-["+this.getObjectId()+","+this.getLength()+","+this.getBitRate()+"] - ["+fragment+","+lastFragment+"]";
	}

	public void setTotalSize(long size) {
		this.totalSize = size;
	}

}
